Skip to content

Add multi-directory static file serving#3920

Closed
ban-xiu wants to merge 17 commits intoactix:mainfrom
ban-xiu:feat-files-array-support
Closed

Add multi-directory static file serving#3920
ban-xiu wants to merge 17 commits intoactix:mainfrom
ban-xiu:feat-files-array-support

Conversation

@ban-xiu
Copy link
Copy Markdown

@ban-xiu ban-xiu commented Feb 12, 2026

PR Type

Feature

PR Checklist

  • Tests for the changes have been added / updated.
  • Documentation comments have been added / updated.
  • A changelog entry has been made for the appropriate packages.
  • Format code with the latest stable rustfmt.
  • (Team) Label with affected crates and semver status.

Overview

Add Files::new_from_array() and Files::new_multiple() methods to support multiple directories from array and iterator, and implement multi-directory static file serving with priority order.
Close #3402

@github-actions github-actions Bot added the A-files project: actix-files label Feb 12, 2026
@ban-xiu ban-xiu closed this Feb 14, 2026
@ban-xiu ban-xiu reopened this Feb 14, 2026
Comment thread actix-files/src/files.rs
Comment thread actix-files/src/service.rs
Comment thread actix-files/src/service.rs Outdated
Comment thread actix-files/src/service.rs
@ban-xiu ban-xiu requested a review from JohnTitor March 1, 2026 08:15
@ban-xiu
Copy link
Copy Markdown
Author

ban-xiu commented Mar 8, 2026

I'm not entirely sure if this modification is sufficient yet.

@ban-xiu ban-xiu closed this Mar 11, 2026
@ban-xiu ban-xiu reopened this Mar 11, 2026
@ban-xiu
Copy link
Copy Markdown
Author

ban-xiu commented Mar 13, 2026

Hi @JohnTitor , could you please help review this PR when you have a moment? Thank you for your time and expertise.

@JohnTitor
Copy link
Copy Markdown
Member

Hey sorry for the delay. I've considered the best API shape and I'd go with #4039 for better structure and error handling. Thanks for the PR anyway.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-files project: actix-files B-semver-patch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

multiple folders as static directories

2 participants